<?
include 'config.inc.php';
$username = @$_POST['username'];
$password = @$_POST['password'];
$img = @$_POST['img_value'];
include 'member.php';

if(!mysql_query("update wwk_chat_user set img='{$img}' WHERE username='{$username}'")){
	echo '更换头像失败。请重试！';
	exit;
 }else{
     echo '更换头像成功';
          //更新聊天记录表的
	 mysql_query("update wwk_chat_msg set img='{$img}' WHERE username='{$username}'");
 }

?>